#automake 
EXTRA_DIST = rc.qtaskd.ini rc.qtaskd.html rc.qtaskd.init base64.php 

install: install-ini

conftodir = "`echo $(sysconfdir)|sed -e 's|/usr/etc|/etc|'`"

sysconftodir = $(conftodir)

install-ini:
	@echo install qtaskd.ini to $(sysconftodir)
	@test -d $(sysconftodir) || mkdir -p $(sysconftodir)
	@test -f $(sysconftodir)/qtaskd.ini \
		|| cp -p rc.qtaskd.ini $(sysconftodir)/qtaskd.ini
	@echo install qtaskd.init to $(sysconftodir)/init.d
	@test -d $(sysconftodir)/init.d || mkdir -p $(sysconftodir)/init.d
	@test -f $(sysconftodir)/init.d/qtaskd \
		|| cp -p rc.qtaskd.init $(sysconftodir)/init.d/qtaskd
	@perl -i -p -e "s@/usr/local/sbin@$(prefix)/bin@g" $(sysconftodir)/init.d/qtaskd 


